home *** CD-ROM | disk | FTP | other *** search
/ Softwarová Záchrana 3 / Softwarova-zachrana-3.bin / Xteq X-Setup / xqdcXSP-Setup-EN.exe / {app} / plugins / XQ NeoPlanet Search.xpl < prev    next >
Text File  |  2000-11-12  |  3KB  |  103 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 5.0"
  2. "TYPE"="1"
  3. "COUNT"="4"
  4. "UIPATH"="Internet\NeoPlanet"
  5. "NAME"="NeoPlanet Search URLs"
  6. "VERSION"="1.10"
  7. "LANGUAGE"="VBScript"
  8. "TEXT 1"="Search #1 Name"
  9. "TEXT 2"="Search #1 URL"
  10. "TEXT 3"="Search #2 Name"
  11. "TEXT 4"="Search #2 URL"
  12. "DESCRIPTION 1"="In the box above, enter the website address you wish to use for the NeoPlanet default search pages."
  13. "DESCRIPTION 2"="The first default URL is http://www.hotbot.com/?MT=%s&SM=SC&DV=0&LG=any&DC=25&DE=2 and the first default name is "Search HotBot""
  14. "DESCRIPTION 3"="The second default URL is http://www.lycos.com/cgi-bin/pursuit?cat=dir&query=%s and the second default name is "Search Lycos""
  15. "DESCRIPTION 4"="You may copy and paste those items into the boxes above to restore the default search engine names and search pages in NeoPlanet."
  16. "DESCRIPTION 5"="Note: These changes affect the drop down search list in NeoPlanet, not the button labled "Search"."
  17. "DESCRIPTION 6"="You should completely exit NeoPlanet, including its taskbar tray icon and restart it for the changes to take effect."
  18. "DESCRIPTION 7"="NeoPlanet is free web browser, available at www.neoplanet.com for download."
  19. "AUTHOR"="CptSiskoX"
  20. "CONTACTURL"="http://members.fortunecity.com/computingx/"
  21. "COPYRIGHT"="(C) 1999 by Xteq Systems"
  22. "COMMENT 1"="Thanks to NeoPlanet for creating a cool and free web browser.  If you don't have it, check out http://www.neoplanet.com and grab a copy."
  23. "COMMENT 2"="Thanks to TeXHeX@xteq.com for helping out."
  24.  
  25.  
  26. sFile="data\data\Default\search.ini"
  27. sFilePath=""
  28.  
  29. sSec1="search1"
  30. sSec2="search2"
  31.  
  32. sV_Name="display"
  33. sV_URL="URL"
  34.  
  35.  
  36. 'Called when the Plugin is started
  37. SUB Plugin_Initialize
  38.  'first try to locate NeoPlanet...
  39.  s=RegReadValue("HKLM\Software\CLASSES\Neo20.Application\shell\open\command\@")
  40.  if len(s)>0 then
  41.     'NP is installed! default result: "C:\PROGRA~1\NEOPLA~1\BIN\NEOPLA~1.EXE "%1"
  42.     'locate the \BIN part and drop the rest
  43.     s=UCase(s) 
  44.     l=InStr(s,"\BIN")    
  45.     if l>0 then
  46.        'looks good!
  47.        s=left(s,l) 'no we have the root
  48.        s=s & sFile 'add the name and path to "search.INI"
  49.  
  50.        sFilePath=s
  51.        'Call DebugMsg(s)
  52.  
  53.        'Final check: Does the file exists?
  54.        if FileExists(sFilePath)then 
  55.  
  56.           'Yiah! We have the file....
  57.           s=INIReadValue(sFilePath,sSec1,sV_Name)
  58.           Call SetUIElement(1,s)
  59.           s=INIReadValue(sFilePath,sSec1,sV_URL)
  60.           Call SetUIElement(2,s)
  61.  
  62.           s=INIReadValue(sFilePath,sSec2,sV_Name)
  63.           Call SetUIElement(3,s)
  64.           s=INIReadValue(sFilePath,sSec2,sV_URL)
  65.           Call SetUIElement(4,s)
  66.  
  67.        else
  68.           Call Disable()
  69.        end if
  70.     else
  71.        Call Disable()
  72.     end if
  73.  else
  74.     Call Disable()
  75.  end if
  76.  
  77.  
  78. END SUB
  79.  
  80. 'Called when the Plugin should validate the Data the user has entered
  81. SUB Plugin_CheckData(ElementIndex)
  82. END SUB
  83.  
  84. 'Called when the Plugin should apply the changes
  85. SUB Plugin_Apply(ElementIndex,ElementSubIndex)
  86.  s=GetUIElement(1)
  87.  Call INIWriteValue(sFilePath,sSec1,sV_Name,s)
  88.  s=GetUIElement(2)
  89.  Call INIWriteValue(sFilePath,sSec1,sV_URL,s)
  90.  
  91.  
  92.  s=GetUIElement(3)
  93.  Call INIWriteValue(sFilePath,sSec2,sV_Name,s)
  94.  s=GetUIElement(4)
  95.  Call INIWriteValue(sFilePath,sSec2,sV_URL,s)
  96.   
  97. END SUB
  98.  
  99. 'Called when the Plugin is about to be removed from memory
  100. SUB Plugin_Terminate
  101. END SUB
  102.  
  103.